package com.mdb.data;

public class Condition {
	public final Op op;
	public final String name;
	public final Object value;

	public Condition(Op op, String name, Object value) {
		this.op = op;
		this.name = name;
		this.value = value;
	}

	public Condition(String name, Object value) {
		this(Op.EQ, name, value);
	}

	public static enum Op {
		EQ(null), NE("$ne"), LT("$lt"), GT("$gt"), LTE("$lte"), GTE("$gte"), IN("$in");

		public final String key;

		private Op(String key) {
			this.key = key;
		}
	}
}
